package com.lsu.command.experiment;

import javax.swing.*;

/**
 * 具体的观察者实现_检测鼠标位置
 *
 * @Author wang suo
 * @Date 2020/10/21 0021 14:55
 * @Version 1.0
 */
public class ConcreteObserverMouseLoc extends JLabel implements Observer {
    @Override
    public void update(Integer n, Integer x, Integer y) {
        this.setText("鼠标位于:(" + x + "," + y + ")");
    }
}
